package com.spark.invoicings.entity;

import com.baomidou.mybatisplus.annotation.*;

import java.math.BigDecimal;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;

/**
 * 客户表
 * 
 * @author sunyan
 * @email sunyan@gmail.com
 * @date 2024-06-13 11:13:53
 */
@Data
@TableName("t_sale_customer")
public class SaleCustomer implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 * 客户ID
	 */
	@TableId(type = IdType.AUTO)
	private Integer customerId;
	/**
	 * 客户名称
	 */
	private String customerName;
	/**
	 * 客户分级：1-一级客户，2-二级客户，3-三级客户
	 */
	private Integer customerRatingId;
	/**
	 * 客户编码
	 */
	private String customerCode;
	/**
	 * 客户来源：其他，线下地推，线上推广，朋友推荐，广告系统
	 */
	private Integer customerSourceId;
	/**
	 * 客户联系电话
	 */
	private String customerPhone;
	/**
	 * 客户联系人
	 */
	private String customerContact;
	/**
	 * 获客时间
	 */
	private Date acquisitionTime;
	/**
	 * 负责销售
	 */
	private String salesRepresentative;
	/**
	 * 地址
	 */
	private String address;
	/**
	 * 开票单位
	 */
	private String billingEntity;
	/**
	 * 纳税人识别号
	 */
	private String taxpayerId;
	/**
	 * 结算方式：1按单付款-现结，2按入库对账-赊账
	 */
	private Integer billingMethodId;
	/**
	 * 开户行
	 */
	private String bankName;
	/**
	 * 银行账号
	 */
	private String bankAccount;
	/**
	 * 销售总额
	 */
	private double totalSales;
	/**
	 * 应收总额
	 */
	private double totalReceivables;
	/**
	 * 已收款金额
	 */
	private double receivedAmount;
	/**
	 * 待回款金额
	 */
	private double pendingCollectionAmount;
	/**
	 * 退款金额
	 */
	private double refundAmount;
	/**
	 * 已开票金额
	 */
	private double invoicedAmount;
	/**
	 * 待开票金额
	 */
	private double pendingInvoicingAmount;
	/**
	 * 对账周期
	 */
	private Integer reconciliation;
	/**
	 * 上次对账
	 */
	private Date startTime;
	/**
	 * 下次对账
	 */
	private Date endTime;
	/**
	 * 逻辑删除
	 * 逻辑删除0(未删除)1,(已删除)
	 */
	@TableLogic
	private Integer deleteStatus;
	/**
	 * 市id
	 */
	private Integer cityId;
	/**
	 * 省id
	 */
	private Integer provinceId;
	/**
	 *客户等级
	 */
    @TableField(exist = false)
	private String customerRating;
	/**
	 * 客户来源
	 */
	@TableField(exist = false)
	private String customerSource;
	/**
	 * 核销方式
	 */
	@TableField(exist = false)
	private String billingMethod;

	public Integer getCustomerId() {
		return customerId;
	}

	public void setCustomerId(Integer customerId) {
		this.customerId = customerId;
	}

	public String getCustomerName() {
		return customerName;
	}

	public void setCustomerName(String customerName) {
		this.customerName = customerName;
	}

	public Integer getCustomerRatingId() {
		return customerRatingId;
	}

	public void setCustomerRatingId(Integer customerRatingId) {
		this.customerRatingId = customerRatingId;
	}

	public String getCustomerCode() {
		return customerCode;
	}

	public void setCustomerCode(String customerCode) {
		this.customerCode = customerCode;
	}

	public Integer getCustomerSourceId() {
		return customerSourceId;
	}

	public void setCustomerSourceId(Integer customerSourceId) {
		this.customerSourceId = customerSourceId;
	}

	public String getCustomerPhone() {
		return customerPhone;
	}

	public void setCustomerPhone(String customerPhone) {
		this.customerPhone = customerPhone;
	}

	public String getCustomerContact() {
		return customerContact;
	}

	public void setCustomerContact(String customerContact) {
		this.customerContact = customerContact;
	}

	public Date getAcquisitionTime() {
		return acquisitionTime;
	}

	public void setAcquisitionTime(Date acquisitionTime) {
		this.acquisitionTime = acquisitionTime;
	}

	public String getSalesRepresentative() {
		return salesRepresentative;
	}

	public void setSalesRepresentative(String salesRepresentative) {
		this.salesRepresentative = salesRepresentative;
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public String getBillingEntity() {
		return billingEntity;
	}

	public void setBillingEntity(String billingEntity) {
		this.billingEntity = billingEntity;
	}

	public String getTaxpayerId() {
		return taxpayerId;
	}

	public void setTaxpayerId(String taxpayerId) {
		this.taxpayerId = taxpayerId;
	}

	public Integer getBillingMethodId() {
		return billingMethodId;
	}

	public void setBillingMethodId(Integer billingMethodId) {
		this.billingMethodId = billingMethodId;
	}

	public String getBankName() {
		return bankName;
	}

	public void setBankName(String bankName) {
		this.bankName = bankName;
	}

	public String getBankAccount() {
		return bankAccount;
	}

	public void setBankAccount(String bankAccount) {
		this.bankAccount = bankAccount;
	}

	public double getTotalSales() {
		return totalSales;
	}

	public void setTotalSales(double totalSales) {
		this.totalSales = totalSales;
	}

	public double getTotalReceivables() {
		return totalReceivables;
	}

	public void setTotalReceivables(double totalReceivables) {
		this.totalReceivables = totalReceivables;
	}

	public double getReceivedAmount() {
		return receivedAmount;
	}

	public void setReceivedAmount(double receivedAmount) {
		this.receivedAmount = receivedAmount;
	}

	public double getPendingCollectionAmount() {
		return pendingCollectionAmount;
	}

	public void setPendingCollectionAmount(double pendingCollectionAmount) {
		this.pendingCollectionAmount = pendingCollectionAmount;
	}

	public double getRefundAmount() {
		return refundAmount;
	}

	public void setRefundAmount(double refundAmount) {
		this.refundAmount = refundAmount;
	}

	public double getInvoicedAmount() {
		return invoicedAmount;
	}

	public void setInvoicedAmount(double invoicedAmount) {
		this.invoicedAmount = invoicedAmount;
	}

	public double getPendingInvoicingAmount() {
		return pendingInvoicingAmount;
	}

	public void setPendingInvoicingAmount(double pendingInvoicingAmount) {
		this.pendingInvoicingAmount = pendingInvoicingAmount;
	}

	public Integer getReconciliation() {
		return reconciliation;
	}

	public void setReconciliation(Integer reconciliation) {
		this.reconciliation = reconciliation;
	}

	public Date getStartTime() {
		return startTime;
	}

	public void setStartTime(Date startTime) {
		this.startTime = startTime;
	}

	public Date getEndTime() {
		return endTime;
	}

	public void setEndTime(Date endTime) {
		this.endTime = endTime;
	}

	public Integer getDeleteStatus() {
		return deleteStatus;
	}

	public void setDeleteStatus(Integer deleteStatus) {
		this.deleteStatus = deleteStatus;
	}

	public Integer getCityId() {
		return cityId;
	}

	public void setCityId(Integer cityId) {
		this.cityId = cityId;
	}

	public Integer getProvinceId() {
		return provinceId;
	}

	public void setProvinceId(Integer provinceId) {
		this.provinceId = provinceId;
	}

	public String getCustomerRating() {
		return customerRating;
	}

	public void setCustomerRating(String customerRating) {
		this.customerRating = customerRating;
	}

	public String getCustomerSource() {
		return customerSource;
	}

	public void setCustomerSource(String customerSource) {
		this.customerSource = customerSource;
	}

	public String getBillingMethod() {
		return billingMethod;
	}

	public void setBillingMethod(String billingMethod) {
		this.billingMethod = billingMethod;
	}
}
